kirchhoff law numerical